package com.example.wc.logindemolistview;

import android.graphics.Color;
import android.os.Bundle;
import android.support.v7.app.AppCompatActivity;
import android.text.Spannable;
import android.text.SpannableString;
import android.text.style.ForegroundColorSpan;
import android.view.Window;
import android.widget.TextView;

/**
 * Created by hui on 2017/2/6.
 */

public class RegisterDemoRegister extends AppCompatActivity {

    private TextView mRegisterTextviewRegister;//我有帐号 立即登录

    protected void onCreate(Bundle savedInstanceState){
        setTheme(R.style.CustomTitleBarTheme);
        super.onCreate(savedInstanceState);
        this.requestWindowFeature(Window.FEATURE_CUSTOM_TITLE);
        setContentView(R.layout.activity_register_demo);
        getWindow().setFeatureInt(Window.FEATURE_CUSTOM_TITLE,R.layout.register_title_bar);
        mRegisterTextviewRegister=(TextView)this.findViewById(R.id.register_textView_register);
        setForegroundColorSpan();
//        Volley vaooley = new Volley();
    }

    //注册页面-立即登录自定义颜色
    private void setForegroundColorSpan() {
        SpannableString spanString = new SpannableString(this.getString(R.string.login_register));
        ForegroundColorSpan span = new ForegroundColorSpan(Color.rgb(255,85,93));
        spanString.setSpan(span, 5, 9, Spannable.SPAN_EXCLUSIVE_EXCLUSIVE);
        mRegisterTextviewRegister.setText(spanString);
    }


}
